layui.use(['form','layer','laydate','table','laytpl'],function(){
    var form = layui.form,
        layer = parent.layer === undefined ? layui.layer : top.layer,
        $ = layui.jquery,
        laydate = layui.laydate,
        laytpl = layui.laytpl,
        table = layui.table;

    //新闻列表
    var tableIns = table.render({
        elem: '#newsList',
        url : '/iprint/admin/getUnpaidOrders',
        method:'get',
        request:{
        	 pageName: 'currPage' //页码的参数名称，默认：page
  			,limitName: 'pageSize' //每页数据量的参数名，默认：limit
        },
        response: {
		  statusName: 'status' //数据状态的字段名称，默认：code
		  ,statusCode: 200 //成功的状态码，默认：0
		  ,countName: 'totalCount' //数据总数的字段名称，默认：count
		  ,dataName: 'list' //数据列表的字段名称，默认：data
		},
        cellMinWidth : 95,
        page : true,
        height : "full-125",
        limit : 20,
        limits : [10,15,20,25],
        id : "newsListTable",
        cols : [[
            {field: 'id', title: '订单id', width:120, align:"center"},
            {field: 'title', title: '订单类型', align:'center',templet:"#newsStatus"},
            {field: 'count', title: '数量', align:'center'},
            {field: 'total', title: '总金额',  align:'center'},
            {field: 'pageType', title: '纸张类型', align:'center'},
            {field: 'pageSize', title: '纸张尺寸', align:'center'},
            {field: 'singleDouble', title: '单双面', align:'center', minWidth:110},
            {field: 'printType', title: '打印类型', align:'center', minWidth:110},
            {field: 'margin', title: '边距', align:'center', minWidth:110},
            {field: 'craftwork', title: '工艺', align:'center', minWidth:110},
            {field: 'changBgc', title: '底色', align:'center', minWidth:110},
            {field: 'pageWeight', title: '纸张重量', align:'center', minWidth:110},
            {title: '操作', width:120, templet:'#newsListBar',fixed:"right",align:"center"}
        ]]
    });

})